package facilius.controller.action.usuario;

import facilius.model.ServiceLocator;
import org.mentawai.core.BaseAction;

/**
 *
 * @author Graciano
 */
public class UsuarioDeleteAction extends BaseAction {

    @Override
    public String execute() throws Exception {
        String consequence = ERROR;
        try {
            Long id = input.getLong("id");
            ServiceLocator.getUsuarioService().delete(id);
            consequence = SUCCESS;
        } catch (Exception e) {
            e.printStackTrace();
        }

        return consequence;
    }
}
